class Solution
{
public:
    bool isSubstringPresent(string s)
    {
        int n = s.size();
        for (int i = 0; i < n - 1; ++i)
        {
            auto sub = s.substr(i, 2);
            reverse(sub.begin(), sub.end());
            if (s.find(sub) != string::npos)
            {
                return true;
            }
        }
        return false;
    }
};